package com.wiloon.java8x.javabasic;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

/**
 * Created by wiloon on 1/22/15.
 */
public class JavaBasic {
    private static Logger logger = LoggerFactory.getLogger(JavaBasic.class);
    private final int finali;
    private final int finalii = 0;

    public JavaBasic() {
        finali = 0;
    }

    public static void main(String[] args) {
        String[] arr = new String[]{"a", "b", "c"};
        logger.debug("arr length=" + arr.length);
        String[] arrFoo = new String[10];
        arrFoo[0] = "abc";
        logger.debug("arrFoo length=" + arrFoo.length);


        int[] array = new int[1];
        array[0] = 1;
        logger.debug("array length=" + array.length);
        logger.debug("array length=" + array.length);

        int[] a[] = new int[4][4];
        a[0][0] = 1;
        logger.debug("a00=" + a[0][0]);
        int b[][] = new int[4][4];
        b[0][0] = 2;
        logger.debug("b00=" + b[0][0]);
        int c[][] = new int[1][4];
        c[0][0] = 2;
        logger.debug("b00=" + c[0][0]);

        int[] d[] = new int[4][];
        d[0] = new int[4];
        d[0][0] = 2;
        logger.debug("d00=" + d[0][0]);


        int[] i[] = {{1, 2}, {1}, {}, {1, 2, 3}};
        logger.debug("i00=" + i[0][0]);
        logger.debug("i01=" + i[0][1]);
        logger.debug("i10=" + i[1][0]);
        logger.debug("i30=" + i[3][0]);

        //int ii[]=new int[2]{1,2};

        int iii[][] = new int[][]{{1, 2, 3}, {4, 5, 6}};
        logger.debug("iii00=" + iii[0][0]);
        logger.debug("iii01=" + iii[0][1]);

        int iiii[][] = {{1, 2}, new int[2]};

        //int iiiii[4]={1,2,3,4};

        char[] ch = new char[5];

        logger.debug("ch=" + ch[0]);

    }
}